<?php class Form_AddForm extends Form_Custom_General {
        public function init() {

		$lgn_id = $this->createElement("hidden", "lgn_id")
                     ->setRequired(FALSE)
                     ->addValidator("NotEmpty", true, array("messages" => array("isEmpty" => "Please enter id")))
                     ->addFilters(array(
                         new Zend_Filter_StringTrim(),
                     ))
                     ->setAttribs(Array("class"=>"span6","placeholder"=>"Id"));
                     $this->addElement($lgn_id);

		$lgn_fname = $this->createElement("text", "lgn_fname")
                     ->setRequired(TRUE)
                     ->addValidator("NotEmpty", true, array("messages" => array("isEmpty" => "Please enter first name")))
                     ->addFilters(array(
                         new Zend_Filter_StringTrim(),
                     ))
                     ->setAttribs(Array("class"=>"inputbox","placeholder"=>"First Name"));
                     $this->addElement($lgn_fname);
					 
		$lgn_lname = $this->createElement("text", "lgn_lname")
                     //->setRequired(True)
                     //->addValidator("NotEmpty", true, array("messages" => array("isEmpty" => "Please enter last name")))
                    //->addValidator(new Zend_Validate_EmailAddress()) 
                    ->addFilters(array(
                         new Zend_Filter_StringTrim(),
                     ))
                     ->setAttribs(Array("class"=>"inputbox","placeholder"=>"Last Name"));
					 $this->addElement($lgn_lname);

		$lgn_email = $this->createElement("text", "lgn_email")
                     ->setRequired(True)
                     ->addValidator("NotEmpty", true, array("messages" => array("isEmpty" => "Please enter email address")))
                    ->addValidator(new Zend_Validate_EmailAddress()) 
                    ->addFilters(array(
                         new Zend_Filter_StringTrim(),
                     ))
                     ->setAttribs(Array("class"=>"inputbox","placeholder"=>"Confirm Email Address"));
            $lgn_email->getValidator('emailAddress')->setMessage("Email address is not valid.", Zend_Validate_EmailAddress::INVALID_FORMAT);
        
            $this->addElement($lgn_email);
			
		$lgn_password = $this->createElement("password", "lgn_password")
                     //->setRequired(TRUE)
                     //->addValidator("NotEmpty", true, array("messages" => array("isEmpty" => "Please enter password")))
                     ->addFilters(array(
                         new Zend_Filter_StringTrim(),
                     ))
                     ->setAttribs(Array("class"=>"inputbox","placeholder"=>"Password"));
                     $this->addElement($lgn_password);
					 
		$confirm_password = $this->createElement("password", "confirm_password")
                     //->setRequired(TRUE)
                     //->addValidator("NotEmpty", true, array("messages" => array("isEmpty" => "Please enter confirm password")))
                     ->addFilters(array(
                         new Zend_Filter_StringTrim(),
                     ))
                     ->setAttribs(Array("class"=>"inputbox","placeholder"=>"Confirm Password"));
                     $this->addElement($confirm_password);
			
			$lgn_zipcode = $this->createElement("text", "lgn_zipcode")
                     //->setRequired(TRUE)
                     //->addValidator("NotEmpty", true, array("messages" => array("isEmpty" => "Please enter zipcode")))
                     ->addFilters(array(
                         new Zend_Filter_StringTrim(),
                     ))
                     ->setAttribs(Array("class"=>"inputbox","rows"=>"3","placeholder"=>"Zip Code"));
                     $this->addElement($lgn_zipcode);

		    $lgn_city = $this->createElement("text", "lgn_city")
                    //->setRequired(FALSE)
                     //->addValidator("NotEmpty", true, array("messages" => array("isEmpty" => "Please enter city")))
                     ->addFilters(array(
                         new Zend_Filter_StringTrim(),
                     ))
                     ->setAttribs(Array("class"=>"inputbox","placeholder"=>"City"));
                     $this->addElement($lgn_city);
					 
			$lgn_state = $this->createElement("select", "lgn_state")
                    //->setRequired(FALSE)
                     //->addValidator("NotEmpty", true, array("messages" => array("isEmpty" => "Please enter state")))
                     ->addFilters(array(
                         new Zend_Filter_StringTrim(),
                     ))
                     ->setAttribs(Array("class"=>"listbox","placeholder"=>"State"));
                     $this->addElement($lgn_state);
					 
			$lgn_address = $this->createElement("textarea", "lgn_address")
                    //->setRequired(TRUE)
                     //->addValidator("NotEmpty", true, array("messages" => array("isEmpty" => "Please enter address")))
                     ->addFilters(array(
                         new Zend_Filter_StringTrim(),
                     ))
                     ->setAttribs(Array("class"=>"textarea", "rows"=>"5","cols"=>"5","placeholder"=>"Street Address"));
                     $this->addElement($lgn_address);

					 
			$lgn_phone = $this->createElement("text", "lgn_phone")
                     //->setRequired(TRUE)
                     //->addValidator("NotEmpty", true, array("messages" => array("isEmpty" => "Please enter phone number")))
                     ->addFilters(array(
                         new Zend_Filter_StringTrim(),
                     ))
                     ->setAttribs(Array("class"=>"inputbox","placeholder"=>"Phone Number"));
                     $this->addElement($lgn_phone);
					 
			$lgn_created = $this->createElement("hidden", "lgn_created")
                     ->setRequired(FALSE)
                     ->addValidator("NotEmpty", true, array("messages" => array("isEmpty" => "Please enter create date")))
                     ->addFilters(array(
                         new Zend_Filter_StringTrim(),
                     ))
                     ->setAttribs(Array("class"=>"span6","placeholder"=>"Create Date"));
                     $this->addElement($lgn_created);

			
		$submit = $this->createElement("submit", "submit")
                //->setLabel('Send message')
				->setAttribs(Array("title" => "Save changes", "class"=>"button"));
        $this->addElement($submit);


        /*$reset = $this->createElement("reset", "Reset")
                ->setAttribs(Array("title" => "Save changes and continue to edit", "class"=>"btn-glow primary"));
        $this->addElement($reset); */  }
        }
?>